package com.issue.common.utils.excel;

/**
 * @Author: xuxiang
 * @Description:系统返回代码枚举
 * @Date: Create in 2018/10/10 10:46
 */
public enum SysReturnCode {
	//操作成功
	RETURN_SUCCESS(10001, "Successful operation"),
	// 异常码定义
	RETURN_ERROR(10002, "Operation failure"),
	SYSTEM_ERROR(10002, "System exception"),
	PARAM_ERROR(10002, "The passed parameter is null"),
	BUSINESS_ERROR(10002, "Service exception"),
	PROXY_CONNECT_ERROR(10002, "The remote interface connection is abnormal. Procedure"),
	SYSTEM_BUSY(10002, "The system is busy, please try again later"),
	LOGINCODE_ERROR(10002, "User does not exist"),
	TOKEN_FORMAT_ERROR(10002, "token resolution error"),
	PROXY_RETURN_ERROR(10002, "The remote interface returned an exception. Procedure");

	/**
	 * 编码
	 */
	private int code;
	/**
	 * 描述
	 */
	private String message;

	SysReturnCode(int code, String message) {
		this.setCode(code);
		this.setMsg(message);
	}

	public int getCode() {
		return code;
	}

	public void setCode(int code) {
		this.code = code;
	}

	public String getMsg() {
		return message;
	}

	public void setMsg(String msg) {
		this.message = msg;
	}

	@Override
	public String toString() {
		return "[" + this.code + "]" + this.message;
	}
}
